package com.gsafety.config;

import com.gsafety.service.PersonService;
import org.springframework.ai.tool.ToolCallbackProvider;
import org.springframework.ai.tool.method.MethodToolCallbackProvider;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @author 蔡建国
 * Date  2025/5/24 15:11
 */
@Configuration
public class PersonConfig {
    @Bean
    public ToolCallbackProvider personToolCallbackProvider(PersonService personService) {
        return MethodToolCallbackProvider.builder()
                .toolObjects(personService)
                .build();
    }
}
